package process;

import databaseAcces.DisplayRequest;
import databaseAcces.InsertionRequest;

public class Checking {

	public int verifyUser(String login,String password, String type) {
		
		DisplayRequest req = new DisplayRequest();
		if (req.verifyUser(login, password, type) == 0 ){
			return 0;
		}
		
		return 1;
	}
	
   public int saveJobPosting(String niveau,String experience,String domaine,String specialite,String lieu_travail,String titre,double salaire,String description) {
	   InsertionRequest request = new InsertionRequest();
	   boolean insert = request.insertPoste(titre, specialite, domaine, salaire, experience, lieu_travail, niveau,description);
	   if (insert)
		   return 0;
	   else
		   return 1;
   }
}
